﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="InviteLinkAudit.aspx.cs" Inherits="Manager_User_PageData_InviteLinkAudit" MasterPageFile="~/Manager/User/PageData/MasterPage.master" %>
<asp:Content ID="Head" ContentPlaceHolderID="HeadPlaceHolder" runat="server">
    <script type="text/javascript" src="../../../js/datetimepicker/calendar.js"></script>
    <script type="text/javascript">
        var MaxPage = <%=MaxPage%>;
        function gopage(pageIndex) {
            if (pageIndex == "")
                return;
            if(pageIndex > MaxPage)
                return;
            if(pageIndex < 1)
                return;
            document.forms[0].action= "InviteLinkAudit.aspx?action=gopage&pageIndex=" + pageIndex; 
            document.forms[0].submit();
        }

        function delAll(){
            var actionForm = deleteAll();
            if(actionForm != null){
                actionForm.action= "InviteLinkAudit.aspx?action=deleteAll&pageIndex=<%=currPageIndex%>"; 
                actionForm.submit();
            }
        }

        function confirmInMoney(msg){
            return window.confirm("确定【" + msg + "】推广奖励审核通过吗?"); 
        }

        function del(id,pageIndex){
           document.forms[0].action= "InviteLinkAudit.aspx?id=" + id + "&action=delete&pageIndex=" + pageIndex;
           document.forms[0].submit();
        }

        function queryFilter(){
            document.forms[0].action= "InviteLinkAudit.aspx?action=queryFilter&pageIndex=1"; 
            document.forms[0].submit();
        }
    </script>
</asp:Content>
<asp:Content ID="Content" ContentPlaceHolderID="ContentPlaceHolder" runat="server">
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
    <tr>
    <td height="30"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="30"><img src="images/tab_03.gif" width="15" height="30" /></td>
        <td width="1101" background="images/tab_05.gif"><img alt="" src="images/311.gif" width="16" height="16" /> <span class="STYLE4">推广奖励审核列表</span></td>
        <td width="281" background="images/tab_05.gif"><table border="0" align="right" cellpadding="0" cellspacing="0">
            <tr>
              <td width="60"><table width="87%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td class="STYLE1"><div align="center">
                        <input type="checkbox" name="checkboxAll" id="checkboxAll" value="0" onclick="chktag()" />
                    </div></td>
                    <td class="STYLE1"><div align="center">全选</div></td>
                  </tr>
              </table></td>
              
              <td width="52"><table width="88%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td class="STYLE1"><div align="center"><img alt="" src="images/083.gif" width="14" height="14" /></div></td>
                    <td class="STYLE1"><div align="center"><a href="#" onclick="delAll()">删除</a></div></td>
                  </tr>
              </table></td>
            </tr>
        </table></td>
        <td width="14"><img alt="" src="images/tab_07.gif" width="14" height="30" /></td>
      </tr>
    </table></td>
  </tr>
 <tr>
    <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="9" background="images/tab_12.gif">&nbsp;</td>
        <td bgcolor="#f3ffe3"><table width="56%" border="0" align="right" cellpadding="0" cellspacing="1">
          <tr>
            <td width="8%" height="26" class="STYLE1"><div align="right" class="STYLE2 STYLE1">用户名</div></td>
            <td width="10%" height="26" class="STYLE1"><div align="center" class="STYLE2 STYLE1"><input type="text" value="<%=userName %>" id="userName" name="userName" style="width:80px" /></div></td>
            <td width="8%" height="18" class="STYLE1"><div align="right" class="STYLE2 STYLE1">起始时间</div></td>
            <td width="10%" height="18" class="STYLE1"><div align="center" class="STYLE2 STYLE1"><input type="text" value="<%=startTime %>" onfocus="setday(this)" id="startTime" name="startTime" style="width:80px" readonly="readonly"/></div></td>
            <td width="8%" height="18" class="STYLE1"><div align="right" class="STYLE2 STYLE1">结束时间</div></td>
            <td width="10%" height="18" class="STYLE1"><div align="center" class="STYLE2 STYLE1"><input type="text" value="<%=endTime %>" onfocus="setday(this)" id="endTime" name="endTime" style="width:80px" readonly="readonly"/></div></td>
            <td width="8%"><table width="88%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td class="STYLE1"><div align="center"><img alt="" src="images/a1.gif" width="14" height="14" /></div></td>
                    <td class="STYLE1"><div align="center"><a href="#" onclick="queryFilter()">查询</a></div></td>
                  </tr>
              </table></td>
          </tr>
        </table></td>
        <td width="9" background="images/tab_16.gif">&nbsp;</td>
      </tr>
    </table></td>
  </tr>
  <tr>
    <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="9" background="images/tab_12.gif">&nbsp;</td>
        <td bgcolor="#f3ffe3"><table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#c0de98" onmouseover="changeto()"  onmouseout="changeback()">
          <tr>
          <td width="6%" height="26" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2 STYLE1">选择</div></td>
            <td width="10%" height="26" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2 STYLE1">推广人用户名</div></td>
            <td width="15%" height="26" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2 STYLE1">IP地址</div></td>
            <td width="8%" height="26" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2 STYLE1">来路</div></td>
            <td width="15%" height="18" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2 STYLE1">日 期</div></td>
            <td width="6%" height="18" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2 STYLE1">审核状态</div></td>
            <td width="6%" height="18" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2 STYLE1">奖励积分</div></td>
            <td width="8%" height="18" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2">操作</div></td>
            <td width="8%" height="18" class="STYLE1 Table_TH_STYLE"><div align="center" class="STYLE2">删除</div></td>
          </tr>
          <% foreach (AD.Model.PayTradeMod pay in Pays){ %>
          <tr>
            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE1">
              <input name="checkbox" type="checkbox" class="STYLE2" value="<%=pay.Out_Trade_No%>" />
            </div></td>
            <td height="18" bgcolor="#FFFFFF" class="STYLE2"><div align="center" class="STYLE2 STYLE1"><%=pay.UserName%></div></td>
            <td height="18" bgcolor="#FFFFFF" class="STYLE2"><div align="center" class="STYLE2 STYLE1"><%=pay.RequestIp%></div></td>
            <td height="18" bgcolor="#FFFFFF" class="STYLE2"><div align="center" class="STYLE2 STYLE1">网络</div></td>
            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1"><%=pay.Commit_Date.ToString("yyyy-MM-dd HH:mm:ss")%></div></td>
            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1"><%=pay.Status == true ? "已审核" : "未审核"%></div></td>
            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1"><%=pay.RewardPoints%></div></td>
            <td height="18" bgcolor="#FFFFFF"><div align="center"><span class="STYLE2"><img alt="" src="images/037.gif" width="9" height="9" /></span>
            <span class="STYLE1">[</span><%if(!pay.Status && pay.IsInMoney==true){ %><a href="InviteLinkAudit.aspx?ids=<%=pay.Out_Trade_No%>&action=inMoney&pageIndex=<%=currPageIndex%>" onclick="return confirmInMoney('<%=pay.UserName %>')">审核</a><%} else{ %><a href="#">已</a><%}%><span class="STYLE1">]</span></div></td>
            <td height="18" bgcolor="#FFFFFF"><div align="center"><span class="STYLE2"><img alt="" src="images/010.gif" width="9" height="9" /></span>
            <span class="STYLE1">[</span><a href="javascript:del('<%=pay.Out_Trade_No%>','<%=currPageIndex%>')" onclick="return confirmDelete('<%=pay.UserName %>')">删除</a><span class="STYLE1">]</span></div></td>
          </tr>
          <%}%>
        </table></td>
        <td width="9" background="images/tab_16.gif">&nbsp;</td>
      </tr>
    </table></td>
  </tr>
  <tr>
    <td height="29"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="29"><img alt="" src="images/tab_20.gif" width="15" height="29" /></td>
        <td background="images/tab_21.gif"><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td width="25%" height="29" nowrap="nowrap"><span class="STYLE1">共<%=MaxSize%>条纪录，当前第<%=currPageIndex + "/" + Pays.Count%>页，每<%=UtilHepler.PAGE_SIZE%>条纪录</span></td>
            <td width="75%" valign="top" class="STYLE1"><div align="right">
              <table width="352" height="20" border="0" cellpadding="0" cellspacing="0">
                <tr>
                  <td width="62" height="22" valign="middle"><div align="right"><img alt="" src="images/first.gif" width="37" height="15" onclick="gopage(1)" /></div></td>
                  <td width="50" height="22" valign="middle"><div align="right"><img alt="" src="images/back.gif" width="43" height="15" onclick="gopage(<%=currPageIndex - 1 %>)"/></div></td>
                  <td width="54" height="22" valign="middle"><div align="right"><img alt="" src="images/next.gif" width="43" height="15" onclick="gopage(<%=currPageIndex + 1 %>)"/></div></td>
                  <td width="49" height="22" valign="middle"><div align="right"><img alt="" src="images/last.gif" width="37" height="15" onclick="gopage(<%=MaxPage %>)" /></div></td>
                  <td width="59" height="22" valign="middle"><div align="right">转到第</div></td>
                  <td width="25" height="22" valign="middle"><span class="STYLE7">
                    <input name="goPageIndex" id="goPageIndex" type="text" class="STYLE1" style="height:10px; width:25px;" size="5" />
                  </span></td>
                  <td width="23" height="22" valign="middle">页</td>
                  <td width="30" height="22" valign="middle"><img alt="" src="images/go.gif" width="37" height="15" onclick="gopage(document.getElementById('goPageIndex').value)" /></td>
                </tr>
              </table>
            </div></td>
          </tr>
        </table></td>
        <td width="14"><img alt="" src="images/tab_22.gif" width="14" height="29" /></td>
      </tr>
    </table></td>
  </tr>
</table>
</asp:Content>
